<h2>Inventarisasi Fisik Bangunan </h2>
<br clear="all"/>

<?php echo form_open($this->uri->uri_string()) ?>
<?php echo form_dropdown("kategori", $this->referensi->get_list_referensi('sapras_kategori_bangunan','id','kategori'),null,null,array('class_label'=>'clear','label'=>'Kategori : ')) ?>
<input type="submit" class="button" value="Tampilkan"/>
<?php echo form_close() ?>
<hr>
<br clear="all">

<table class="table tablepager">
    <thead>
        <tr>
            <th width="10px">No.</th>
            <th width="50px">Kode Bangunan</th>
            <th>Nama Bangunan</th>
            <th width="50px">Kondisi</th>
            <th width="50px">Luas Lantai<br>( M<?php echo persegi() ?> )</th>
            <th width="150px">Keterangan</th>
            <th width="120px">Aksi</th>
        </tr>
    </thead>
    <tbody>
        <?php $no=1 ?>
        <?php foreach($data as $detail): ?>
            <tr>
                <td class="center"><?php echo $no++ ?></td>
                <td class="center"><?php echo $detail['kode_bangunan']?></td>
                <td><?php echo $detail['nama_bangunan']?></td>
                <td class="center"><?php echo $detail['kondisi']?></td>
                <td class="right"><?php echo $detail['luas_lantai']?></td>
                <td ><?php echo $detail['keterangan']?></td>
                <td class="center">
                    <?php echo anchor("sapras/bangunan/detail/".$detail['kode_bangunan'],"detail") ?> |
                    <?php echo anchor("sapras/bangunan/edit/".$detail['kode_bangunan'],"edit") ?> |
                    <?php echo anchor("sapras/bangunan/delete/".$detail['kode_bangunan'],"delete",array("onclick"=>"return confirm('Apakah Anda yakin akan menghapus data ini?')")) ?>
                </td>
            </tr>
        <?php endforeach ?>
    </tbody>
</table>
<?php $this->load->view("elements/pager") ?>
<?php echo anchor("sapras/bangunan/add/".$_POST['kategori'], "Tambah Data", array("class"=>"button")) ?>
